# Maintainer: 
pkgname=dhcp-helper
pkgver=1.2
pkgrel=0
pkgdesc="DHCP relay server"
url="http://www.thekelleys.org.uk/dhcp-helper/"
arch="all"
license="GPL-2.0-only OR GPL-3.0-only"
depends=""
makedepends="linux-headers"
install=""
subpackages="$pkgname-doc $pkgname-openrc"
source="http://www.thekelleys.org.uk/dhcp-helper/dhcp-helper-$pkgver.tar.gz
	compile-only-once.patch
	$pkgname.initd
	$pkgname.confd"
options="!check"

build() {
	cd "$builddir"
	make PREFIX=/usr version="${pkgver}-r${pkgrel}"
}

package() {
	cd "$builddir"
	make PREFIX=/usr version="${pkgver}-r${pkgrel}" MANDIR=/usr/share/man DESTDIR="$pkgdir" install

	install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
        install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
}

sha512sums="2f81d729a261454aac8ae9b508d3f319155fc9bdb80b0822317f244ea20fa471ee214f1a1df284375612344751308998591c5e4ac742fd34d720db8e65306ba5  dhcp-helper-1.2.tar.gz
1d80211ee0fa9c27261749924ee0d623da7d54d61103705cb421eed2ad84c6f87de119f470aeb3504144be0d553b773aecf552e53c5698110d8b3a36bfe9061a  compile-only-once.patch
241719be1136ceaca984ada662a8d57e4ed2c2d9b4fba1249796d79af50b40432bc6e479b6c815dee4ac133c8e83aca87fbd5df90ba28e97297ed0347ef7c0f7  dhcp-helper.initd
0281a04898e8b63c37a159876fe7b27f47416a2b95701a3820f65b8bfc52ea56026c66cb875f1e44f1cac40a47a4ef53dc94d85de9bdaca032ef1a144c0f2884  dhcp-helper.confd"
